package com.atguigu.book.dao.impl;

import com.atguigu.book.dao.UserDAO;
import com.atguigu.book.pojo.User;
import com.atguigu.myssm.basedao.BaseDAO;

/**
 * @ClassName: UserDAOImpl
 * @Description:
 * @Author: wty
 * @Date: 2022/12/12
 */

public class UserDAOImpl extends BaseDAO<User> implements UserDAO {
    /**
     * @param
     * @return com.atguigu.book.pojo.User
     * @description //验证用户登录
     * @param: uname
     * @param: pwd
     * @date 2022/12/12 19:37
     * @author wty
     **/
    @Override
    public User getUser(String uname, String pwd) {
        String sqlStr = "SELECT * FROM bookdb.`t_user` a WHERE a.`uname` = ? AND a.`pwd` = ?";
        return load(sqlStr, uname, pwd);
    }
}
